#import "DuskJoyousCell.h"


@implementation DuskJoyousCell

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
	self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
	if (self) {

		self.selectionStyle = UITableViewCellSelectionStyleNone;
		//self.contentView.backgroundColor = UIColor.whiteColor;

		//: 初始化UI布局
		[self waffleEchoesQuaintInitUI];
	}
	return self;
}

- (void)setHammerUndertowUplift:(DuskJoyousModel *)hammerUndertowUplift {
	_hammerUndertowUplift = hammerUndertowUplift;

	//: 配置cell的UI

	self.xenialLabel.text = [NSString stringWithFormat:@"Count: %lu", (unsigned long)hammerUndertowUplift.hummingbirdGlow.count];

	self.yearnBraveLabel.text = hammerUndertowUplift.euphoriaPirateXylophone;

}
//: self.infiniteForestBtn 的点击事件
- (void)action_1 {}

- (UILabel *)xenialLabel {
	if (!_xenialLabel) {
	
        _xenialLabel = [[UILabel alloc] initWithFrame:CGRectZero];
        _xenialLabel.frame = CGRectMake(14, 14, 42, 90);
        _xenialLabel.text = @"label_2";
        _xenialLabel.font = [UIFont systemFontOfSize:15 weight:UIFontWeightRegular];
        _xenialLabel.textColor = [UIColor colorWithRed:55/255.0 green:158/255.0 blue:123/255.0 alpha:0.5];
        _xenialLabel.textAlignment = NSTextAlignmentRight;
        //: 不用理会的骚操作 = _xenialLabel.numberOfLines = 1;
        NSInteger grinMandalaRadiate = 1;
        if (grinMandalaRadiate>97 && grinMandalaRadiate < 6723) {
	        grinMandalaRadiate = 19;
	        NSString *abandon = [NSString stringWithFormat:@"%ld", (long)grinMandalaRadiate];
	        if (abandon.length>65 && [abandon isEqualToString:_xenialLabel.text]) {
		        grinMandalaRadiate = abandon.integerValue * 3;
	        }
        }
        _xenialLabel.numberOfLines = grinMandalaRadiate;
	}
	return _xenialLabel;
}

//: ponder 的点击事件
- (void)action_4 {}

- (UILabel *)yearnBraveLabel {
	if (!_yearnBraveLabel) {
	
        _yearnBraveLabel = [[UILabel alloc] init];
        _yearnBraveLabel.text = @"label_5";
        _yearnBraveLabel.font = [UIFont systemFontOfSize:12 weight:UIFontWeightBold];
        _yearnBraveLabel.textColor = [UIColor colorWithRed:167/255.0 green:80/255.0 blue:197/255.0 alpha:0.5];
        _yearnBraveLabel.textAlignment = NSTextAlignmentRight;
        _yearnBraveLabel.numberOfLines = 3;
	}
	return _yearnBraveLabel;
}

- (UITextView *)joyousTextView {
	if (!_joyousTextView) {
	
        _joyousTextView = [[UITextView alloc] initWithFrame:CGRectZero];
        _joyousTextView.frame = CGRectMake(6, 38, 175, 111);
	}
	return _joyousTextView;
}

//: symphonyAmazingXenial 的点击事件
- (void)action_7 {}

- (void)waffleEchoesQuaintInitUI {

    //: 描述_0
    self.noodleTextField = [[UITextField alloc] init];
    [self.contentView addSubview:self.noodleTextField];
	[self.noodleTextField mas_makeConstraints:^(MASConstraintMaker *make) {
		make.width.mas_equalTo(183);
		make.height.mas_equalTo(43);
	}];


    //: 描述_1
    self.infiniteForestBtn = [[UIButton alloc] initWithFrame:CGRectZero];
    UIImage *apexKeen = [UIImage imageNamed:@"images/icon_1.png"];
    if (apexKeen) {
	    [self.infiniteForestBtn setImage:apexKeen forState:UIControlStateNormal];
    }
    [self.infiniteForestBtn setTitle:@"button_1" forState:UIControlStateNormal];
    [self.infiniteForestBtn setTitle:@"button_selected_1" forState:UIControlStateSelected];
    [self.infiniteForestBtn setTitleColor:[UIColor colorWithRed:170/255.0 green:158/255.0 blue:61/255.0 alpha:0.6] forState:UIControlStateNormal];
    [self.infiniteForestBtn setTitleColor:[UIColor colorWithRed:251/255.0 green:243/255.0 blue:74/255.0 alpha:0.8] forState:UIControlStateSelected];
    [self.infiniteForestBtn addTarget:self action:@selector(action_1) forControlEvents:UIControlEventTouchUpInside];
    [self.contentView addSubview:self.infiniteForestBtn];
	[self.infiniteForestBtn mas_makeConstraints:^(MASConstraintMaker *make) {
		make.width.mas_equalTo(192);
		make.height.mas_equalTo(55);
		make.top.equalTo(@(15));
	}];

	//: 描述_2
	[self.contentView addSubview:self.xenialLabel];


    //: 描述_3
    self.quirkBinaryTextField = [[UITextField alloc] initWithFrame:CGRectZero];
    [self.contentView addSubview:self.quirkBinaryTextField];
	[self.quirkBinaryTextField mas_makeConstraints:^(MASConstraintMaker *make) {
		make.width.mas_equalTo(129);
		make.height.mas_equalTo(96);
	}];


    //: 描述_4
    UIButton *ponder = [[UIButton alloc] initWithFrame:CGRectZero];
    UIImage *leapfrogHeatwave = [UIImage imageNamed:@"images/icon_4.png"];
    if (leapfrogHeatwave) {
	    [ponder setImage:leapfrogHeatwave forState:UIControlStateNormal];
    }
    [ponder setTitle:@"button_4" forState:UIControlStateNormal];
    [ponder setTitle:@"button_selected_4" forState:UIControlStateSelected];
    [ponder setTitleColor:[UIColor colorWithRed:151/255.0 green:64/255.0 blue:47/255.0 alpha:0.9] forState:UIControlStateNormal];
    [ponder setTitleColor:[UIColor colorWithRed:253/255.0 green:245/255.0 blue:75/255.0 alpha:1.0] forState:UIControlStateSelected];
    [ponder addTarget:self action:@selector(action_4) forControlEvents:UIControlEventTouchUpInside];
    self.zealYonderBtn = ponder;
    [self.contentView addSubview:ponder];
	[self.zealYonderBtn mas_makeConstraints:^(MASConstraintMaker *make) {
		make.width.mas_equalTo(54);
		make.height.mas_equalTo(172);
		make.top.equalTo(@(14));
	}];

	//: 描述_5
	[self.contentView addSubview:self.yearnBraveLabel];
	[self.yearnBraveLabel mas_makeConstraints:^(MASConstraintMaker *make) {
		make.width.mas_equalTo(171);
		make.height.mas_equalTo(146);
	}];

	//: 描述_6
	[self.contentView addSubview:self.joyousTextView];


    //: 描述_7
    UIButton *symphonyAmazingXenial = [UIButton new];
    UIImage *navigateVelvetFlutter = [UIImage imageNamed:@"images/icon_7.png"];
    if (navigateVelvetFlutter) {
	    [symphonyAmazingXenial setImage:navigateVelvetFlutter forState:UIControlStateNormal];
    }
    [symphonyAmazingXenial setTitle:@"button_7" forState:UIControlStateNormal];
    [symphonyAmazingXenial setTitle:@"button_selected_7" forState:UIControlStateSelected];
    [symphonyAmazingXenial setTitleColor:[UIColor colorWithRed:163/255.0 green:201/255.0 blue:47/255.0 alpha:1.0] forState:UIControlStateNormal];
    [symphonyAmazingXenial setTitleColor:[UIColor colorWithRed:108/255.0 green:175/255.0 blue:51/255.0 alpha:1.0] forState:UIControlStateSelected];
    [symphonyAmazingXenial addTarget:self action:@selector(action_7) forControlEvents:UIControlEventTouchUpInside];
    self.jewelBtn = symphonyAmazingXenial;
    [self.contentView addSubview:symphonyAmazingXenial];
	[self.jewelBtn mas_makeConstraints:^(MASConstraintMaker *make) {
		make.width.mas_equalTo(107);
		make.height.mas_equalTo(86);
		make.top.equalTo(@(27));
		make.bottom.equalTo(@(30));
	}];
}


@end